<template>
  <h1>
    这是 first 页面
  </h1>
  <button @click="go">去second页面</button>

  <button id="toggle-dark-mode" @click="toggle">Toggle Dark Mode</button>
    <button id="reset-to-system">Reset to System Theme</button>
</template>

<script setup lang="ts">
import { useRouter } from 'vue-router';



const router = useRouter()
const go = () => {
  router.push('/second');
};
const toggle =async()=>{

  const isDarkMode = await window.darkMode.toggle()

}
</script>

<style scoped>

</style>